\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{intersections}
% 预定义全局样式，方便统一修改所有样式
% 可以作为tikzpicture环境或者绘制命令可选参数
\tikzset{my_grid/.style={semithick,color=blue!50}}
\begin{document}

    % \tikz\draw (0pt,0pt)--(20pt,6pt);
    % \tikz\fill[fill=orange](1ex,1ex) circle (1ex);
    % \tikz \draw[thick,rounded corners=8pt]%
    % (0,0) -- (0,2) -- (1,3.25) -- (2,2) -- (2,0) -- (0,2) -- (2,2) -- (0,0) -- (2,0);
    % \tikzpicture
    % \draw (-1.5,0) -- (1.5,0);
    % \draw (0,-1.5) -- (0,1.5);
    % \endtikzpicture.
    % \begin{tikzpicture}
    %     \filldraw [gray] (0,0) circle [radius=2pt]
    %     (1,1) circle [radius=2pt]
    %     (2,1) circle [radius=2pt]
    %     (2,0) circle [radius=2pt];
    %     \draw (0,0) .. controls (1,1) and (2,1) .. (2,0);
    % \end{tikzpicture}
    % \tikz{\draw (0,0) circle [radius=1cm]}

    % 可以自定义线条的点线复杂样式
    % \begin{tikzpicture}[my_grid,dash pattern=on 0.2cm off 0.1cm]
    %     \draw (0,0) rectangle (2,2);
    % \end{tikzpicture}
    % \begin{tikzpicture}
    %     \tikz \draw[rotate=-30] (0,0) ellipse [x radius=2cm, y radius=1cm];
    %     \clip (-1,-1) rectangle (1,1);
    %     \draw[step=.5cm,my_grid][scale=3] (-1.4,-1.4) grid (1.4,1.4);
    %     \draw[scale=3] (0,0) circle [radius=1cm];
    %     \draw (0,0) arc [start angle=1,end angle=315,
    %                     x radius=1.75cm,y radius=1cm];
    %     \draw (0,0) arc [start angle=0,end angle=60,radius=1cm];
    % \end{tikzpicture}
    %   \tikz \draw (0,0) rectangle (1,1) (0,0) parabola (1,1);
    %   A sin \tikz {\draw[x=1cm,y=1cm] (0,0) sin (1,1)} curve
    % \begin{tikzpicture}
    %     \filldraw[fill=green!20!white,draw=black] (0,0) -- (1,0) arc (0:30:1) --cycle;
    %     \draw[rotate=180] (0,0) -- (1,0) arc (0:30:1) --cycle;
    % \end{tikzpicture}
    % \begin{tikzpicture}[scale=3]
        % \clip (-0.1,-0.2) rectangle (1.1,0.75);
        % \draw[step=.5cm,gray,very thin] (-1.4,-1.4) grid (1.4,1.4);
        % \draw[->][>=latex] (-1.5,0) -- (1.5,0);
        % \draw[->][>=latex] (0,-1.5) -- (0,1.5);
        % \draw (0,0) circle [radius=1cm];
        % \filldraw[fill=green!20,draw=green!50!black] (0,0) -- (3mm,0mm)
        % arc [start angle=0, end angle=30, radius=3mm] -- cycle;
        % \draw[red,very thick] (30:1cm) -- +(0,-0.5);
        % \draw[red,very thick] (30:1cm) -- (30:1cm |- 0,0);
        % \draw[blue,very thick] (30:1cm) ++(0,-0.5) -- (0,0);
        % \draw[orange,very thick] (0:1cm)--(1,{tan(30)});
        % \foreach \p in {-1,...,1}
        % \draw[red] (\p cm,-1pt)--(\p cm,1pt);
    % \end{tikzpicture}
\end{document}